﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using PerceptiveMCAPI;
using PerceptiveMCAPI.Types;

namespace PerceptiveMCAPI_Test
{
   public partial class show_listsForEmail : System.Web.UI.UserControl
   {
      public void Display ( listsForEmailOutput output )
      {
         this.Visible = true;
         lblHeader.Text = string.Format( "Email: {0}, List count: {1}",
            output.inputParms.email_address, output.result.Count.ToString() );
         //
         gvLists.DataSource = output.result;
         gvLists.DataBind();
         //
         if ( gvLists.HeaderRow != null )
            gvLists.HeaderRow.Cells[0].Text = "List Id";
      }

   }
}